@import "../../styles/colors.less";

.cm-radio-group{
  &.cm-radio-group-stick{
    display: inline-block;
    vertical-align: middle;

    &:after{
      content: ' ';
      display: table;
      clear: both;
    }
    .cm-checkbox{
      border: 1px solid #d9d9d9;
      height: 32px;
      line-height: 31px;
      padding: 0 12px;
      cursor: pointer;
      background: #fff;
      border-left: 1px solid transparent;
      float: left;
      -webkit-transition: all .3s;
      transition: all .3s;
      margin-right: 0;
      &.disabled{
        background: #f7f7f7;
      }

      &.cm-checkbox-checked{
        border-color: @color-blue;
        border-left: 1px solid @color-blue!important;
        color: @color-blue;
      }
      &:first-child{
        border-left: 1px solid #d9d9d9;
        border-top-left-radius: 3px;
        border-bottom-left-radius: 3px;
      }
      &:last-child{
        border-top-right-radius: 3px;
        border-bottom-right-radius: 3px;
      }
      .cm-checkbox-outter{
        display: none;
      }
      label{
        cursor: pointer;
      }
    }
  }
}

.cm-form-group-invalid .cm-radio-group{
  .cm-checkbox {
    color: @color-danger;
  }
}

.cm-radio-group{
  &.cm-radio-group-small{
    .cm-checkbox{
      height: 24px;
      line-height: 23px;
    }
  }
  &.cm-radio-group-large{
    .cm-checkbox{
      height: 40px;
      line-height: 39px;
    }
  }
}
